<a id="fetch">Make a jsonp request.</a>
<hr/>
<div id="loading"></div>
<div id="response"></div>

<script src="/depender/build?require=More/Request.JSONP,Core/Element.Event"></script>
<script>
$('fetch').addEvent('click', function(){
	new Request.JSONP({
		log: true,
		url: '/echo/jsonp',
		onComplete: function(data){
			$('response').set('text', 'success!');
			$('loading').set('text', '');
		},
		onRequest: function(){
			$('loading').set('text', 'Loading...');
		}
	}).send();
});

</script>
